$(document).on("pjax:complete", function () {
  const catalogMagnet = new Vue({
    el: "#catalogMagnet",
    data: {
      message: "你好！欢迎访问我的主页小何blog!",
      link: [],
      postnum: [],
      //这里是磁贴背景图片
      img: [
        "https://gitee.com/he_chaoming/blog_tuchuang/raw/master/20201025/!MJQ23!5LXoo.jpg",
        "https://gitee.com/he_chaoming/blog_tuchuang/raw/master/20201025/IBtNTKVmrIA!.jpg",
        "https://gitee.com/he_chaoming/blog_tuchuang/raw/master/20201025/0!@rCBQrDFZX.jpg",
        "http://01.027cgb.com/632500/v2-05f58dfdb66d3c426a0798d543b5166d_r.jpg",
        "http://01.027cgb.com/632500/v2-84c2f52f300829f1b05996bd7582298e_r.jpg",
        "http://01.027cgb.com/632500/v2-46f39e708485745b0ff98dac11563e62_r.jpg",
        "http://kp.027cgb.cn/632500/v2-585bd5092b35b15acb710c2a74440a93_r.jpg",
        "http://kp.027cgb.cn/632500/v2-2828cf150efd15e5b1c1ee112b78e5f3_r.jpg",
      ],
      //这里是磁贴描述信息
      describe: [
        "前端笔记咯咯咯",
        "后端笔记啦啦啦",
        "学习内容总结。",
        "软件和网站分享。",
        "代码和项目案例。",
        "四六级和程序英语。",
        "PR和AE等学习。",
        "随缘笔记哈哈。",
      ],
      //这里是磁贴的文字颜色
      figLetColor: { color: "white" },
      //这里是磁贴的文字遮罩
      figLetimg: {
        backgroundImage:
          "linear-gradient(to bottom,rgba(0, 0, 0, 0.4) 25%,rgba(16,16,16,0) 100%)",
      },
      //这里是当磁贴图片为透明背景png时默认展示的背景颜色
      figbackColor: { background: "#000000 URL()" },
      //这里是当磁贴图片为透明背景png时默认展示的凹凸效果
      figShadow: { boxShadow: "inset 3px 3px 18px 0px rgba(50,50,50, 0.4)" },
    },
  });

  catalogMagnet.link = $(".categoryMagnetitem")
    .children()
    .children()
    .children("a");
  catalogMagnet.postnum = $(".categoryMagnetitem")
    .children()
    .children()
    .children("span");
  let linecolor = catalogMagnet.figLetColor.color;
  $("<style type='text/css' id='dynamic-after' />").appendTo("head");
  $("#dynamic-after").text(
    ".magnetname:after{background:" + linecolor + "!important}",
  );
});
const catalogMagnet = new Vue({
  el: "#catalogMagnet",
  data: {
    message: "你好！欢迎访问我的主页小何blog!",
    link: [],
    postnum: [],
    //这里是磁贴背景图片
    img: [
      "https://gitee.com/he_chaoming/blog_tuchuang/raw/master/20201025/!MJQ23!5LXoo.jpg",
      "https://gitee.com/he_chaoming/blog_tuchuang/raw/master/20201025/IBtNTKVmrIA!.jpg",
      "https://gitee.com/he_chaoming/blog_tuchuang/raw/master/20201025/0!@rCBQrDFZX.jpg",
      "http://01.027cgb.com/632500/v2-05f58dfdb66d3c426a0798d543b5166d_r.jpg",
      "http://01.027cgb.com/632500/v2-84c2f52f300829f1b05996bd7582298e_r.jpg",
      "http://01.027cgb.com/632500/v2-46f39e708485745b0ff98dac11563e62_r.jpg",
      "http://kp.027cgb.cn/632500/v2-585bd5092b35b15acb710c2a74440a93_r.jpg",
      "http://kp.027cgb.cn/632500/v2-2828cf150efd15e5b1c1ee112b78e5f3_r.jpg",
    ],
    //这里是磁贴描述信息
    describe: [
      "前端笔记咯咯咯",
      "后端笔记啦啦啦",
      "学习内容总结。",
      "软件和网站分享。",
      "代码和项目案例。",
      "四六级和程序英语。",
      "PR和AE等学习。",
      "随缘笔记哈哈。",
    ],
    //这里是磁贴的文字颜色
    figLetColor: { color: "white" },
    //这里是磁贴的文字遮罩
    figLetimg: {
      backgroundImage:
        "linear-gradient(to bottom,rgba(0, 0, 0, 0.4) 25%,rgba(16,16,16,0) 100%)",
    },
    //这里是当磁贴图片为透明背景png时默认展示的背景颜色
    figbackColor: { background: "#000000 URL()" },
    //这里是当磁贴图片为透明背景png时默认展示的凹凸效果
    figShadow: { boxShadow: "inset 3px 3px 18px 0px rgba(50,50,50, 0.4)" },
  },
});

catalogMagnet.link = $(".categoryMagnetitem")
  .children()
  .children()
  .children("a");
catalogMagnet.postnum = $(".categoryMagnetitem")
  .children()
  .children()
  .children("span");
let linecolor = catalogMagnet.figLetColor.color;
$("<style type='text/css' id='dynamic-after' />").appendTo("head");
$("#dynamic-after").text(
  ".magnetname:after{background:" + linecolor + "!important}",
);
